<template>
	<view>
		<block v-for="(fan, i) in fans" :key="i">
			<view class="item-box">
				<image :src="fan.avatar" style="width: 100rpx;height: 100rpx;border-radius: 50rpx;"></image>
				<view style="margin-left: 20rpx;">{{fan.nickName}}</view>
			</view>
		</block>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				fans: []
			}
		},
		methods: {
			getMyFans() {

				this.$u.api.getMyFans({
						userId: this.$store.state.userinfo.id,
					})
					.then(res => {
						this.fans = res.data;
						console.log(res);
					});

			}
		},
		onLoad() {
			this.getMyFans();
		}
	}
</script>

<style lang="scss">
.item-box{
	display: flex;
	flex-direction: row;
	align-items: center;
	 border-bottom-width:1rpx;
	border-bottom-style: solid;
	border-bottom-color:  #E5E5E5;
	padding-top: 10rpx;
	padding-bottom: 10rpx;
	padding-left: 20rpx;
}


</style>
